package com.controller.order;

import com.client.DadaApiResponse;
import com.request.AddOrderReq;
import com.service.OrderAddService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author zhang
 */
@RestController
@Api(value = "OrderAddController")
public class OrderAddController {
    @Autowired
    private OrderAddService orderAddService;

    @PostMapping("/api/order/addOrder")
    @ApiOperation(value = "orderAdd", notes = "orderAdd")
    public DadaApiResponse orderAdd(@RequestBody AddOrderReq addOrderReq) {
        return orderAddService.orderAdd(addOrderReq);
    }
}
